#ifndef MODEL_H
#define MODEL_H

#include "Point.h"
#include "Vecteur.h"
#include "Triangle.h"
#include "Texture.h"
#include "Objet.h"
#include "Phong.h"
#include "glm_bis.h"

class Model : public Objet{
protected:
		Point * points;
		int nbPoints;
		Triangle * triangles;
		int nbTriangles;
		Vecteur * normales;
		int nbNormales;
		Phong * materiaux;
		int nbMateriaux;
		void readModel(Mmodel &mod);
	public:
		Model ();
		Model (char * name);
		void intersection(const Rayon &,Intersection &);
		bool ombre(const Rayon &, double);
		virtual ~Model () {delete[]points;delete[]triangles;delete[]normales;delete[]materiaux;}
		void setIllum(Illumination * i);
		void setTexture(Texture * t);
};
#endif